
import { Scene } from 'react-native-router-flux';

//引入各个模块的路由
import Home from './TabItems/Home'
import Mine from './TabItems/Mine'

import MineScene from './MineItem/Scenes'
import HomeScene from './HomeItem/Scenes'

//集合路由
let itemScene = [
    HomeScene,
    MineScene,
];

module.exports = (
    <Scene key="pageRoot" type="reset" hideNavBar={true}>
        <Scene key="tabbar" tabs={true}>
            <Scene key="Home"
                   title="首页"
                   component={Home}
                   hideNavBar={true} />
            <Scene key="Mine" title="我的" component={Mine} hideNavBar={true} />
        </Scene>
        {itemScene.map(item =>{
            let hideNavBar = item.hideNavBar && item.hideNavBar == true ? true:false;
            return <Scene key={item.key} component={item.comp} /> ;
            })
        }
    </Scene>
)